<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class News extends CI_Controller {

    function __construct() {
       parent::__construct();
       //header('Content-type: text/plain; charset=utf-8');
   }
    
    public function getNews () {
        header('Content-type: text/plain; charset=utf-8');
	$obj = array ('errorCode'=>0, 'errordesc' => "", 'news'=>

		array (
			'objectName' => 'News',
			'arrayOfObjects' =>
				array(
					array (
						'newsId' => 1,
						'title' => 'tytyl',
						'content' => 'tresc'
					)
				)
		)

	);
	echo json_encode($obj);
    }
    
    public function uploadNews () {
    
    }
}
